<template>
	<!-- 图片字体，
			接收字体类型type
			继承字体大小，颜色，框大小 -->
	<i class="iconfont" :class="cname" :style="styles"></i>
</template>

<script>
let icons = {
	jizu: 'icon-zhujizu',
	bili: 'icon-bili',
	nengliang: 'icon-leijinengliang',
	month: 'icon-yue',
	today: 'icon-dangri',
	factory: 'icon-gongchang',
	workshop: 'icon-web-icon-',
	product: 'icon-shengchanxian',
	unit: 'icon-shebeishuliang',
	
	close: 'icon-guanbi1',
	user: 'icon-denglu',
	pwd: 'icon-mima',
	reg: 'icon-yanzhengma2'
}
export default{
	props:{
		type:{
			type: String,
			default: 'none'
		},
		styles:{
			type: Object
		}
	},
	computed:{
		cname(){
			return icons[this.type];
		}
	}
}
</script>

<style scoped>
@import '//at.alicdn.com/t/font_2577641_kbzldebr78.css';
i{
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 100%;
	transition: color .3s;
	font-size: inherit;
	font-weight: normal;
}
</style>
